#ifndef  __BSP_BLE_H__
#define  __BSP_BLE_H__

#include "sys.h"

#define  BLE_UART                   USART0 
#define  BLE_UART_IRQn              USART0_IRQn
/*!< Ble uart tx pin */
#define  BLE_GPIO_PORT              GPIOA
#define  BLE_TX_PIN                 GPIO_PIN_10
#define  BLE_TX_PIN_MODE            GPIO_MODE_AF
#define  BLE_TX_PIN_PUPD            GPIO_PUPD_PULLUP
#define  BLE_TX_PIN_OTYPE           GPIO_OTYPE_PP
#define  BLE_TX_PIN_SPD             GPIO_OSPEED_50MHZ
/*!< Ble uart rx pin */
#define  BLE_RX_PIN                 GPIO_PIN_9
#define  BLE_RX_PIN_MODE            GPIO_MODE_AF
#define  BLE_RX_PIN_PUPD            GPIO_PUPD_PULLUP
#define  BLE_RX_PIN_OTYPE           GPIO_OTYPE_PP
#define  BLE_RX_PIN_SPD             GPIO_OSPEED_50MHZ
/*!< Ble mode pin */
#define  BLE_FUNC_GPIO_PORT         GPIOB
#define  BLE_MOD_PIN                GPIO_PIN_10
#define  BLE_MOD_PIN_MODE           GPIO_MODE_OUTPUT
#define  BLE_MOD_PIN_PUPD           GPIO_PUPD_NONE
#define  BLE_MOD_PIN_OTYPE          GPIO_OTYPE_PP
#define  BLE_MOD_PIN_SPD            GPIO_OSPEED_2MHZ
/*!< Ble mode fb pin */
#define  BLE_FB_PIN                 GPIO_PIN_14
#define  BLE_FB_PIN_MODE            GPIO_MODE_OUTPUT
#define  BLE_FB_PIN_PUPD            GPIO_PUPD_NONE
#define  BLE_FB_PIN_OTYPE           GPIO_OTYPE_PP
#define  BLE_FB_PIN_SPD             GPIO_OSPEED_2MHZ
/*!< Ble wake up pin */
#define  BLE_WKUP_PIN               GPIO_PIN_15
#define  BLE_WKUP_PIN_MODE          GPIO_MODE_OUTPUT
#define  BLE_WKUP_PIN_PUPD          GPIO_PUPD_NONE
#define  BLE_WKUP_PIN_OTYPE         GPIO_OTYPE_PP
#define  BLE_WKUP_PIN_SPD           GPIO_OSPEED_2MHZ

extern void bsp_ble_sendbuff(uint8_t *buff, uint32_t len);
extern void bsp_ble_config(void);

#endif   /* __BSP_BLE_H__ */
